<!DOCTYPE html>
<html>
<head>
    <title>问答社区</title>
    <meta charset="utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="/js/bootstrap-4.1.1-dist/css/bootstrap.min.css">
    <script src="/js/jquery/jquery.min.js"></script>
    <script src="/js/bootstrap-4.1.1-dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="/css/font/css/font-awesome.min.css" />
    <link rel="stylesheet" href="/css/reset.css" />
    <link rel="stylesheet" href="/css/myInfo.css" />
    <script src="/js/plugins/jrender/jrender.min.js"></script>
    <link rel="stylesheet" href="/js/plugins/dialog2/dialog.css" />
    <script src="/js/plugins/dialog2/dialog.min.js"></script>
    <script src="/js/plugins/form/jquery.form.js"></script>
    <script src="/js/checkLogin.js"></script>
    <script src="/js/common.js"></script>
</head>
<style>
    body {
        background: url("/upload/2.bmp") no-repeat center center fixed;
        -webkit-background-size: cover;
        -moz-background-size: cover;
        -o-background-size: cover;
        background-size: cover;
    }

    button{
        width: 310px;
        height:100px;
        background: url("/upload/2.bmp") no-repeat;
        border-style: none;
    }
</style>

<body>
<div class="search-head">
    <div class="row nav-search">
        <div class="col">
            <a href="javascript:history.go(-1);">
                <span><i class="fa fa-chevron-left"></i></span>
            </a>
        </div>
        <div class="col">
            <span>社区问答</span>
        </div>
        <div class="col"></div>
    </div>
</div>

<div class="tab-content" id="pills-tabContent">
    <div class="tab-pane fade active show" id="pills-top">
        <div class="container community">
            <div class="row nav-box">
                <div class="col"align="center">
                   <button> <a href="communityQA.html"><i class="fa fa-ask fa-fw"></i> <h2 >社区问答</h2></a></button>
                </div>
            </div>
        </div>
    </div>
<hr>
        <div class="row nav-box">
            <div class="col" align="center">
                <div class="container mineTroubles">
                    <button> <a href="travelTroubles.html"><i class="fa fa-ask fa-fw"></i><h2>我的问答</h2></a> </button>
                </div>
            </div>
        </div>
<hr>
     <!--   <div class="container travelTroubles">
            <dl class="list" render-loop="list">
                <dd>
                    <a href="JavaScript;" render-key="list.id" render-fun="handle">
                        <h6 class="title desc" render-html="list.title"></h6>
                    </a>
                    <p>问于 <span render-html="list.lastUpdateTime"></span>
                        <span class="span-right">
                        <i class="fa "></i><span class="nums">0 &nbsp;</span>回答
                        <i class="fa "></i><span class="nums">0 &nbsp;</span>浏览</span>
                    </p>
                    <hr>
                </dd>
            </dl>
        </div>-->

</div>


<script>
  /*  $(function () {

        var currentPage = 1;
        var travels;
        var pages;

        // 从本地session中取出缓存的对象,渲染到页面
        var user = JSON.parse(sessionStorage.getItem("user"));
        // 发请求获取数据
        $.get(baseUrl+"/users/" + user.id + "/travelTroubles", {pageSize: 2,state:1}, function (data) {
            renderView(data);
            console.log(data);
            travels = data.list;
            // 需要用到总页数,所以先获取
            pages = data.pages;
            console.log(pages);
        });

        $(window).scroll(function () {
            console.log(isEnd());
            if (isEnd()) {
                if (currentPage < pages) {
                    currentPage++;
                    console.log(currentPage);
                    $.get(baseUrl+"/users/" + user.id + "/travelTroubles", {
                        currentPage: currentPage,
                        pageSize: 2,
                        state:1
                    }, function (data) {
                        $.merge(travels, data.list);
                        renderView({list: travels});
                    });
                } else {
                    $(document).dialog({
                        type: 'notice',
                        infoText: '我也是有底线的',
                        autoClose: 1500,
                        position: 'bottom'  // center: 居中; bottom: 底部
                    });
                }
            }
        })

    });

    function renderView(data) {
        $(".travelTroubles").renderValues(data, {
            handle: function (ele, value) {
                $(ele).attr("href", "/mine/troubleContent.html?id=" + value);
            }
        });
    }
*/
</script>
</body>
</html>